#!/bin/bash

#main函数
	#sh 02_init_hostnameAndYum
	#sh 03_init_updateAndsynUpdateTime
	#sh 04_init_iptablesAndselinux
	#sh 05_init_dnsAndssh
	#sh 06_init_dnsAndssh
	#sh 07_init_environment

	#list="02_init_hostnameAndYum 03_init_updateAndsynUpdateTime 04_init_iptablesAndselinux 05_init_dnsAndssh 06_init_dnsAndssh 07_init_environment" 
	#for i in $list
	#	do
	#		ssh root@$1 "bash" < $i
	#	done
IP="192.168.137.22"
scp /opt/shell/invironment_shell/* root@$IP:/opt/
ssh root@$1 << remote
	cd /opt/
	sh 02_init_hostnameAndYum
        sh 03_init_updateAndsynUpdateTime
        sh 04_init_iptablesAndselinux
        sh 05_init_networkfile
        sh 06_init_dnsAndssh
        sh 07_init_environment		
remote
